package Mediator_Pattern.The_United_Nation;

// -*-coding:utf-8 -*-
//人员：刘陆鑫
//班级：19软3
//学号；2019110218
public class WHO_Un_Mediator extends Un_Mediator{
    public China china;
    public USA usa;

    @Override
    public void connect(Country e) {
        if(e== china){
            china.out();
            System.out.println("通过WHO链接");
            usa.in();
        }
        else if(e==usa){
            usa.out();
            System.out.println("通过WHO链接");
            china.in();
        }
        else{
            System.out.println("链接失败");
        }
    }
}
